# Contributor: Peter Bui <pnutzh4x0r@gmail.com>
# Maintainer: Fabian Affolter <fabian@affolter-engineering.ch>
pkgname=py3-feedparser
_pkgname=feedparser
pkgver=6.0.11
pkgrel=0
pkgdesc="Python3 feed parser for RSS and Atom"
options="!check" # Tests are py2 only
url="https://github.com/kurtmckee/feedparser"
arch="noarch"
license="BSD-2-Clause"
depends="python3 py3-sgmllib3k"
makedepends="py3-gpep517 py3-setuptools py3-wheel"
subpackages="$pkgname-pyc"
source="https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz"
builddir="$srcdir"/$_pkgname-$pkgver

replaces="py-feedparser" # Backwards compatibility
provides="py-feedparser=$pkgver-r$pkgrel" # Backwards compatibility

build() {
	gpep517 build-wheel \
		--wheel-dir .dist \
		--output-fd 3 3>&1 >&2
}

package() {
	python3 -m installer -d "$pkgdir" \
		.dist/*.whl
}

sha512sums="
bb164cf81bfbb552d80617a8af0ac10f2e8184fbed6bdbb6707b915d8140544f08eb9e318d756efd33fd683f362dc81429b64b8ad8bf22cbae989da92d66db02  feedparser-6.0.11.tar.gz
"
